-
Notifications
You must be signed in to change notification settings - Fork 3
fix : 서버 요청 용량 수정 #206
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix : 서버 요청 용량 수정 #206
Conversation
문제: - 1MB 이상 이미지 업로드 시 413 에러 발생 - 원래 의도는 5MB 이상 이미지일 때만 에러 처리 - Spring Boot 기본 multipart 제한(1MB)으로 인해 백엔드 도달 전 차단 - 커스텀 에러 메시지 미제공 해결: - application.properties에 multipart 설정 추가
|
Caution Review failedThe pull request is closed. Walkthrough
Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related PRs
Suggested reviewers
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
📜 Recent review detailsConfiguration used: Repository UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (2)
src/main/resources/application.properties (2)
194-194:spring.servlet.multipart.enabled=true설정은 중복될 수 있습니다.Spring Boot는 기본적으로 멀티파트 지원을 활성화하므로, 이 속성은 명시할 필요가 없을 수 있습니다. 필요한 경우가 아니면 제거하는 것을 고려하세요.
190-196: 설정값에 대한 설명이나 문맥 추가를 권장합니다.현재 설정이 이슈 #205를 해결하기 위한 것임을 명확히 하기 위해, 5MB와 10MB 제한값을 선택한 이유를 간단한 주석으로 추가하면 향후 유지보수 시 도움이 될 것입니다.
# ======================== # Multipart File Upload # ======================== + # 이슈 #205: 멀티파트 업로드 크기 제한 설정 (#205 참고) server.tomcat.max-swallow-size=-1 spring.servlet.multipart.enabled=true spring.servlet.multipart.max-file-size=5MB spring.servlet.multipart.max-request-size=10MB
📜 Review details
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
src/main/resources/application.properties
🔇 Additional comments (2)
src/main/resources/application.properties (2)
189-196: 멀티파트 업로드 설정이 PR 목표와 일치합니다.추가된 설정들이 이슈 #205의 문제(2MB 이상 이미지 거부)를 해결하기 위한 올바른 접근입니다:
server.tomcat.max-swallow-size=-1: Tomcat이 요청을 거부하기 전에 Spring이 처리하도록 보장max-file-size=5MB: 명시된 의도(5MB 이상만 거부)와 일치max-request-size=10MB: 멀티파트 오버헤드를 고려한 적절한 크기 비율
189-196: 이 설정의 속성 이름들은 Spring Boot 3.5.0에서 유효하고 최신입니다.검증 결과, 사용된 모든 속성 이름이 Spring Boot 3.5.0에서 정확하며 더 이상 사용 중인 것으로 확인되었습니다:
spring.servlet.multipart.enabled— 멀티파트 지원 활성화spring.servlet.multipart.max-file-size— 파일당 최대 크기 (기본값: 1MB)spring.servlet.multipart.max-request-size— 전체 요청 최대 크기 (기본값: 10MB)server.tomcat.max-swallow-size— Tomcat 요청 본문 최대 크기이 속성들은 Spring Boot 3.x에서 변경되지 않았으며, 지정된 값(5MB, 10MB, -1)도 모두 유효한 형식입니다.
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.